home *** CD-ROM | disk | FTP | other *** search
/ PC World 2007 December / PCWorld_2007-12_cd.bin / domacnost a kancelar / autoit / autoit-v3-setup.exe / Examples / Helpfile / _GUICtrlEditLineScroll.au3 < prev    next >
Text File  |  2007-09-08  |  2KB  |  37 lines

  1. #include <GUIConstants.au3>
  2. #include <GuiEdit.au3>
  3.  
  4. opt('MustDeclareVars', 1)
  5.  
  6. Dim $myedit, $msg, $Btn_Scrollv, $Btn_Scrollh
  7.  
  8. GUICreate("Edit Line Scroll", 392, 254)
  9.  
  10. $myedit = GUICtrlCreateEdit("AutoIt v3 is a freeware BASIC-like scripting language designed for automating the Windows GUI." & @CRLF, 140, 32, 121, 97, BitOR($ES_AUTOVSCROLL, $WS_VSCROLL, $ES_MULTILINE, $WS_HSCROLL))
  11. GUICtrlSetLimit($myedit, 1500)
  12. $Btn_Scrollh = GUICtrlCreateButton("Scroll Horiz", 75, 140, 90, 30)
  13. $Btn_Scrollv = GUICtrlCreateButton("Scroll Vert", 190, 140, 90, 30)
  14.  
  15. ; will be append dont' forget 3rd parameter
  16. GUICtrlSetData($myedit, "It uses a combination of simulated keystrokes, mouse movement and window/control manipulation" & @CRLF & _
  17.       "in order to automate tasks in a way not possible or reliable with other languages (e.g. VBScript" & @CRLF & _ 
  18.       "and SendKeys)." & @CRLF & _ 
  19.       'AutoIt was initially designed for PC "roll out" situations to configure thousands of PCs, but with the' & @CRLF & _ 
  20.       "arrival of v3 it is also well suited to performing home automation and the scripting of repetitive" & @CRLF & _ 
  21.       "tasks." & @CRLF & @CRLF & "AutoIt can:" & @CRLF & @CRLF & "Execute Windows and DOS executables", 1)
  22.  
  23. GUISetState()
  24.  
  25. ; Run the GUI until the dialog is closed
  26. While 1
  27.    $msg = GUIGetMsg()
  28.    Select
  29.       Case $msg = $GUI_EVENT_CLOSE
  30.          ExitLoop
  31.       Case $msg = $Btn_Scrollv
  32.          _GUICtrlEditLineScroll ($myedit, 0, 1)
  33.       Case $msg = $Btn_Scrollh
  34.          _GUICtrlEditLineScroll ($myedit, 10, 0)
  35.    EndSelect
  36. WEnd
  37.